package com.mmd.manage.dao;

import com.mmd.common.entity.MmdRoute;
import com.mmd.common.entity.MmdSupplier;
import com.mmd.common.mapper.MmdRouteMapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

public interface RouteDao extends MmdRouteMapper {
	int insertRoute(MmdRoute route);
	
	MmdRoute getRouteInfo(@Param("routeNo")String routeNo);
	
	int updateRoute(MmdRoute route);
	
	List<MmdRoute> getRouteListBySupplier(@Param("supplierCode")String supplierCode);

	List<MmdRoute> getValidRouteListBySupplier(@Param("supplierCode")String supplierCode);

	List<MmdRoute> getRouteListBySupplierCodeList(@Param("supplierCodes") List<MmdSupplier> supplier);

	int getRouteNumberByTimeBetween(@Param("routeNo")String routeNo, @Param("routeName")String routeName, @Param("validStartTime") Date validStartTime, @Param("validEndTime") Date validEndTime);

	List<MmdRoute> getRouteByRouteName(@Param("routeName")String routeName);
}
